package xy.http.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;
import xy.http.entity.User;
import xy.http.util.OkHttpUtil;

import javax.annotation.Resource;

@RestController
public class HttpController {

    @Resource
    OkHttpUtil okHttpUtil;

    @GetMapping("doGet")
    public String doGet(String url){
        return okHttpUtil.doGet(url);
    }

    @GetMapping("doPost")
    public String doPost(String url){
        return okHttpUtil.doGet(url);
    }
}
